package com.nyist.myticket.core.factory;

import java.text.SimpleDateFormat;
import java.util.Date;

/**
 * @author yangxiaogen
 * @date 2021/7/27 17:21
 */
public class GetTimeFactory {

    public static String getNowTime() {

        Date nowTime = new Date(System.currentTimeMillis());
        System.out.println(System.currentTimeMillis());
        SimpleDateFormat sdFormatter = new SimpleDateFormat("yyyy-MM-dd HH:mm:dd");
        String retStrFormatNowDate = sdFormatter.format(nowTime);

        return retStrFormatNowDate;
    }
}
